home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 4 / Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso / Development / Source / POVSRC / SOURCE / QuickTimeComponents.h < prev    next >
Text File  |  1993-11-30  |  62KB  |  1,547 lines

  1. /************************************************************
  2.  
  3. Created: Tuesday, June 8, 1993 at 3:10 PM
  4.  QuickTimeComponents.h
  5.  C Interface to the Macintosh Libraries
  6.  
  7.  
  8.  Copyright Apple Computer, Inc. 1991, 1992
  9.  All rights reserved
  10.  
  11. ************************************************************/
  12.  
  13.  
  14. #ifndef __QUICKTIMECOMPONENTS__
  15. #define __QUICKTIMECOMPONENTS__
  16.  
  17. #ifndef __COMPONENTS__
  18. #include <Components.h>
  19. #endif
  20.  
  21. #ifndef __IMAGECOMPRESSION__
  22. #include <ImageCompression.h>
  23. #endif
  24.  
  25. #ifndef __MOVIES__
  26. #include <Movies.h>
  27. #endif
  28.  
  29. #ifndef __QUICKDRAW__
  30. #include <QuickDraw.h>
  31. #endif
  32.  
  33. #ifndef __VIDEO__
  34. #include <Video.h>
  35. #endif
  36.  
  37.  
  38.     #define clockComponentType         'clok'
  39.     #define systemTickClock         'tick'            /* subtype: 60ths since boot        */
  40.     #define systemSecondClock        'seco'            /* subtype: seconds since 1904        */
  41.     #define systemMillisecondClock    'mill'            /* subtype: 1000ths since boot        */
  42.     #define systemMicrosecondClock    'micr'            /* subtype: 1000000ths since boot    */
  43.     
  44.     enum {
  45.         kClockRateIsLinear = 1,
  46.         kClockImplementsCallBacks = 2
  47.     };
  48.     
  49.     #define ClockGetTime GetClockTime
  50.  
  51.  
  52. #ifdef __cplusplus
  53. extern "C" {
  54. #endif __cplusplus
  55.  
  56. /** These are Clock procedures **/
  57.  
  58. pascal ComponentResult ClockGetTime (ComponentInstance aClock, TimeRecord *out)  = {0x2F3C,0x4,0x1,0x7000,0xA82A};
  59.  
  60. pascal QTCallBack ClockNewCallBack (ComponentInstance aClock, TimeBase tb, short callBackType)  = {0x2F3C,0x6,0x2,0x7000,0xA82A};
  61.  
  62. pascal ComponentResult ClockDisposeCallBack (ComponentInstance aClock, QTCallBack cb)  = {0x2F3C,0x4,0x3,0x7000,0xA82A};
  63.  
  64. pascal ComponentResult ClockCallMeWhen (ComponentInstance aClock, QTCallBack cb, long param1, long param2, long param3)  = {0x2F3C,0x10,0x4,0x7000,0xA82A};
  65.  
  66. pascal ComponentResult ClockCancelCallBack (ComponentInstance aClock, QTCallBack cb)  = {0x2F3C,0x4,0x5,0x7000,0xA82A};
  67.  
  68. pascal ComponentResult ClockRateChanged (ComponentInstance aClock, QTCallBack cb)  = {0x2F3C,0x4,0x6,0x7000,0xA82A};
  69.  
  70. pascal ComponentResult ClockTimeChanged (ComponentInstance aClock, QTCallBack cb)  = {0x2F3C,0x4,0x7,0x7000,0xA82A};
  71.  
  72. pascal ComponentResult ClockSetTimeBase (ComponentInstance aClock, TimeBase tb)  = {0x2F3C,0x4,0x8,0x7000,0xA82A};
  73.  
  74. pascal ComponentResult ClockStartStopChanged (ComponentInstance aClock, QTCallBack cb, Boolean startChanged, Boolean stopChanged)  = {0x2F3C,0x8,0x9,0x7000,0xA82A};
  75.  
  76. pascal ComponentResult ClockGetRate (ComponentInstance aClock, Fixed *rate)  = {0x2F3C,0x4,0xA,0x7000,0xA82A};
  77.  
  78. #ifdef __cplusplus
  79. }
  80. #endif __cplusplus
  81. enum {
  82.     kClockGetTimeSelect = 0x1,
  83.     kClockNewCallBackSelect = 0x2,
  84.     kClockDisposeCallBackSelect = 0x3,
  85.     kClockCallMeWhenSelect = 0x4,
  86.     kClockCancelCallBackSelect = 0x5,
  87.     kClockRateChangedSelect = 0x6,
  88.     kClockTimeChangedSelect = 0x7,
  89.     kClockSetTimeBaseSelect = 0x8,
  90.     kClockStartStopChangedSelect = 0x9,
  91.     kClockGetRateSelect = 0xA 
  92. };
  93.  
  94.     /*
  95.         General Sequence Grab stuff
  96.     */
  97.     
  98.     typedef ComponentInstance SeqGrabComponent;
  99.     
  100.     typedef ComponentInstance SGChannel;
  101.     
  102.     #define SeqGrabComponentType 'barg'
  103.     #define SeqGrabChannelType 'sgch'
  104.     #define SeqGrabPanelType 'sgpn'
  105.  
  106.     #define SeqGrabCompressionPanelType 'comp'
  107.     #define SeqGrabSourcePanelType 'sour'
  108.  
  109.     enum {
  110.         seqGrabToDisk = 1,
  111.         seqGrabToMemory = 2,
  112.         seqGrabDontUseTempMemory = 4,
  113.         seqGrabAppendToFile = 8,
  114.         seqGrabDontAddMovieResource = 16,
  115.         seqGrabDontMakeMovie = 32,
  116.         seqGrabPreExtendFile = 64
  117.     };
  118.     typedef unsigned long SeqGrabDataOutputEnum;
  119.  
  120.     enum {
  121.         seqGrabRecord = 1,
  122.         seqGrabPreview = 2,
  123.         seqGrabPlayDuringRecord = 4
  124.     };
  125.     typedef unsigned long SeqGrabUsageEnum;
  126.  
  127.     enum {
  128.         seqGrabHasBounds = 1,
  129.         seqGrabHasVolume = 2,
  130.         seqGrabHasDiscreteSamples = 4
  131.     };
  132.     typedef unsigned long SeqGrabChannelInfoEnum;
  133.  
  134.     typedef struct seqGrabFrameInfo {
  135.         long        frameOffset;
  136.         long        frameTime;
  137.         long        frameSize;
  138.         SGChannel    frameChannel;
  139.         long        frameRefCon;
  140.     } seqGrabFrameInfo;
  141.     
  142.     enum {
  143.         grabPictOffScreen = 1,
  144.         grabPictIgnoreClip = 2,
  145.         grabPictCurrentImage = 4
  146.     };
  147.     #define sgFlagControlledGrab (1)
  148.  
  149.     typedef pascal OSErr (*SGDataProc)(SGChannel c, Ptr p, long len, long *offset, long chRefCon,
  150.                 TimeValue time, short writeType, long refCon);
  151.  
  152.     typedef struct SGDeviceName {
  153.         Str63            name;
  154.         Handle            icon;
  155.         long            flags;
  156.         long            refCon;
  157.         long            reserved;        // zero
  158.     } SGDeviceName;
  159.  
  160.     #define sgDeviceNameFlagDeviceUnavailable (1)
  161.  
  162.     typedef struct SGDeviceListRecord {
  163.         short            count;
  164.         short            selectedIndex;
  165.         long            reserved;        // zero
  166.         SGDeviceName    entry[1];
  167.     } SGDeviceListRecord, *SGDeviceListPtr, **SGDeviceList;
  168.  
  169.     #define sgDeviceListWithIcons (1)
  170.     #define sgDeviceListDontCheckAvailability (2)
  171.  
  172.     enum {
  173.         seqGrabWriteAppend,
  174.         seqGrabWriteReserve,
  175.         seqGrabWriteFill
  176.     };
  177.  
  178.     enum {
  179.         seqGrabUnpause = 0,
  180.         seqGrabPause = 1,
  181.         seqGrabPauseForMenu = 3
  182.     };
  183.     enum {
  184.         channelFlagDontOpenResFile = 2,
  185.         channelFlagHasDependency = 4
  186.     };
  187.  
  188.     typedef pascal Boolean (*SGModalFilterProcPtr)(DialogPtr theDialog, EventRecord *theEvent,
  189.                 short *itemHit, long refCon);
  190.  
  191.     enum {
  192.         sgPanelFlagForPanel = 1
  193.     };
  194.  
  195.  
  196.  
  197.     #define channelPlayNormal 0
  198.     #define channelPlayFast 1
  199.     #define channelPlayHighQuality 2
  200.     #define channelPlayAllData 4
  201.  
  202. #ifdef __cplusplus
  203. extern "C" {
  204. #endif __cplusplus
  205. pascal ComponentResult SGInitialize (SeqGrabComponent s)  = {0x2F3C,0,0x1,0x7000,0xA82A};
  206.  
  207. pascal ComponentResult SGSetDataOutput (SeqGrabComponent s, FSSpec *movieFile, long whereFlags)  = {0x2F3C,0x8,0x2,0x7000,0xA82A};
  208.     
  209. pascal ComponentResult SGGetDataOutput (SeqGrabComponent s, FSSpec *movieFile, long *whereFlags)  = {0x2F3C,0x8,0x3,0x7000,0xA82A};
  210.  
  211. pascal ComponentResult SGSetGWorld (SeqGrabComponent s, CGrafPtr gp, GDHandle gd)  = {0x2F3C,0x8,0x4,0x7000,0xA82A};
  212. pascal ComponentResult SGGetGWorld (SeqGrabComponent s, CGrafPtr *gp, GDHandle *gd)  = {0x2F3C,0x8,0x5,0x7000,0xA82A};
  213.  
  214. pascal ComponentResult SGNewChannel (SeqGrabComponent s, OSType channelType, SGChannel *ref)  = {0x2F3C,0x8,0x6,0x7000,0xA82A};
  215. pascal ComponentResult SGDisposeChannel (SeqGrabComponent s, SGChannel c)  = {0x2F3C,0x4,0x7,0x7000,0xA82A};
  216.  
  217. pascal ComponentResult SGStartPreview (SeqGrabComponent s)  = {0x2F3C,0,0x10,0x7000,0xA82A};
  218. pascal ComponentResult SGStartRecord (SeqGrabComponent s)  = {0x2F3C,0,0x11,0x7000,0xA82A};
  219. pascal ComponentResult SGIdle (SeqGrabComponent s)  = {0x2F3C,0,0x12,0x7000,0xA82A};
  220. pascal ComponentResult SGStop (SeqGrabComponent s)  = {0x2F3C,0,0x13,0x7000,0xA82A};
  221.  
  222. pascal ComponentResult SGPause (SeqGrabComponent s, Byte pause)  = {0x2F3C,0x2,0x14,0x7000,0xA82A};
  223.  
  224. pascal ComponentResult SGPrepare (SeqGrabComponent s, Boolean prepareForPreview, Boolean prepareForRecord)  = {0x2F3C,0x4,0x15,0x7000,0xA82A};
  225. pascal ComponentResult SGRelease (SeqGrabComponent s)  = {0x2F3C,0,0x16,0x7000,0xA82A};
  226.  
  227. pascal Movie SGGetMovie (SeqGrabComponent s)  = {0x2F3C,0,0x17,0x7000,0xA82A};
  228.  
  229. pascal ComponentResult SGSetMaximumRecordTime (SeqGrabComponent s, unsigned long ticks)  = {0x2F3C,0x4,0x18,0x7000,0xA82A};
  230. pascal ComponentResult SGGetMaximumRecordTime (SeqGrabComponent s, unsigned long *ticks)  = {0x2F3C,0x4,0x19,0x7000,0xA82A};
  231.  
  232. pascal ComponentResult SGGetStorageSpaceRemaining (SeqGrabComponent s, unsigned long *bytes)  = {0x2F3C,0x4,0x1A,0x7000,0xA82A};
  233. pascal ComponentResult SGGetTimeRemaining (SeqGrabComponent s, long *ticksLeft)  = {0x2F3C,0x4,0x1B,0x7000,0xA82A};
  234.  
  235. pascal ComponentResult SGGrabPict (SeqGrabComponent s, PicHandle *p, const Rect *bounds,
  236.                 short offscreenDepth, long grabPictFlags)  = {0x2F3C,0xE,0x1C,0x7000,0xA82A};
  237.  
  238. pascal ComponentResult SGGetLastMovieResID (SeqGrabComponent s, short *resID)  = {0x2F3C,0x4,0x1D,0x7000,0xA82A};
  239.  
  240. pascal ComponentResult SGSetFlags (SeqGrabComponent s, long sgFlags)  = {0x2F3C,0x4,0x1E,0x7000,0xA82A};
  241.  
  242. pascal ComponentResult SGGetFlags (SeqGrabComponent s, long *sgFlags)  = {0x2F3C,0x4,0x1F,0x7000,0xA82A};
  243.  
  244. pascal ComponentResult SGSetDataProc (SeqGrabComponent s, SGDataProc proc, long refCon)  = {0x2F3C,0x8,0x20,0x7000,0xA82A};
  245.  
  246. pascal ComponentResult SGNewChannelFromComponent (SeqGrabComponent s, SGChannel *newChannel, Component sgChannelComponent)  = {0x2F3C,0x8,0x21,0x7000,0xA82A};
  247.  
  248. pascal ComponentResult SGDisposeDeviceList (SeqGrabComponent s, SGDeviceList list)  = {0x2F3C,0x4,0x22,0x7000,0xA82A};
  249.  
  250. pascal ComponentResult SGAppendDeviceListToMenu (SeqGrabComponent s, SGDeviceList list, MenuHandle mh)  = {0x2F3C,0x8,0x23,0x7000,0xA82A};
  251.  
  252. pascal ComponentResult SGSetSettings (SeqGrabComponent s, UserData ud, long flags)  = {0x2F3C,0x8,0x24,0x7000,0xA82A};
  253.  
  254. pascal ComponentResult SGGetSettings (SeqGrabComponent s, UserData *ud, long flags)  = {0x2F3C,0x8,0x25,0x7000,0xA82A};
  255.  
  256. pascal ComponentResult SGGetIndChannel (SeqGrabComponent s, short index, SGChannel *ref, OSType *chanType)  = {0x2F3C,0xA,0x26,0x7000,0xA82A};
  257.  
  258. pascal ComponentResult SGUpdate (SeqGrabComponent s, RgnHandle updateRgn)  = {0x2F3C,0x4,0x27,0x7000,0xA82A};
  259.  
  260. pascal ComponentResult SGGetPause (SeqGrabComponent s, Byte *paused)  = {0x2F3C,0x4,0x28,0x7000,0xA82A};
  261.  
  262. pascal ComponentResult SGSettingsDialog (SeqGrabComponent s, SGChannel c, short numPanels, Component *panelList, long flags, SGModalFilterProcPtr proc, long procRefNum)  = {0x2F3C,0x16,0x29,0x7000,0xA82A};
  263.  
  264. pascal ComponentResult SGGetAlignmentProc (SeqGrabComponent s, AlignmentProcRecordPtr alignmentProc)  = {0x2F3C,0x4,0x2A,0x7000,0xA82A};
  265.  
  266. pascal ComponentResult SGSetChannelSettings (SeqGrabComponent s, SGChannel c, UserData ud, long flags)  = {0x2F3C,0xC,0x2B,0x7000,0xA82A};
  267.  
  268. pascal ComponentResult SGGetChannelSettings (SeqGrabComponent s, SGChannel c, UserData *ud, long flags)  = {0x2F3C,0xC,0x2C,0x7000,0xA82A};
  269.  
  270.  
  271.  
  272. /*
  273.     calls from Channel to seqGrab
  274. */
  275.  
  276. pascal ComponentResult SGWriteMovieData (SeqGrabComponent s, SGChannel c, Ptr p, long len, long *offset)  = {0x2F3C,0x10,0x100,0x7000,0xA82A};
  277. pascal ComponentResult SGAddFrameReference (SeqGrabComponent s, seqGrabFrameInfo *frameInfo)  = {0x2F3C,0x4,0x101,0x7000,0xA82A};
  278. pascal ComponentResult SGGetNextFrameReference (SeqGrabComponent s, seqGrabFrameInfo *frameInfo,
  279.                     TimeValue *frameDuration, long *frameNumber)  = {0x2F3C,0xC,0x102,0x7000,0xA82A};
  280. pascal ComponentResult SGGetTimeBase (SeqGrabComponent s, TimeBase *tb)  = {0x2F3C,0x4,0x103,0x7000,0xA82A};
  281. pascal ComponentResult SGSortDeviceList (SeqGrabComponent s, SGDeviceList list)  = {0x2F3C,0x4,0x104,0x7000,0xA82A};
  282. pascal ComponentResult SGAddMovieData (SeqGrabComponent s, SGChannel c, Ptr p, long len, long *offset, long chRefCon, TimeValue time, short writeType)  = {0x2F3C,0x1A,0x105,0x7000,0xA82A};
  283. pascal ComponentResult SGChangedSource (SeqGrabComponent s, SGChannel c)  = {0x2F3C,0x4,0x106,0x7000,0xA82A};
  284.  
  285.  
  286. /*** Sequence Grab CHANNEL Component Stuff ***/
  287.  
  288. pascal ComponentResult SGSetChannelUsage (SGChannel c, long usage)  = {0x2F3C,0x4,0x80,0x7000,0xA82A};
  289. pascal ComponentResult SGGetChannelUsage (SGChannel c, long *usage)  = {0x2F3C,0x4,0x81,0x7000,0xA82A};
  290.  
  291. pascal ComponentResult SGSetChannelBounds (SGChannel c, const Rect *bounds)  = {0x2F3C,0x4,0x82,0x7000,0xA82A};
  292. pascal ComponentResult SGGetChannelBounds (SGChannel c, Rect *bounds)  = {0x2F3C,0x4,0x83,0x7000,0xA82A};
  293.  
  294. pascal ComponentResult SGSetChannelVolume (SGChannel c, short volume)  = {0x2F3C,0x2,0x84,0x7000,0xA82A};
  295. pascal ComponentResult SGGetChannelVolume (SGChannel c, short *volume)  = {0x2F3C,0x4,0x85,0x7000,0xA82A};
  296.  
  297. pascal ComponentResult SGGetChannelInfo (SGChannel c, long *channelInfo)  = {0x2F3C,0x4,0x86,0x7000,0xA82A};
  298.  
  299. pascal ComponentResult SGSetChannelPlayFlags (SGChannel c, long playFlags)  = {0x2F3C,0x4,0x87,0x7000,0xA82A};
  300. pascal ComponentResult SGGetChannelPlayFlags (SGChannel c, long *playFlags)  = {0x2F3C,0x4,0x88,0x7000,0xA82A};
  301.  
  302. pascal ComponentResult SGSetChannelMaxFrames (SGChannel c, long frameCount)  = {0x2F3C,0x4,0x89,0x7000,0xA82A};
  303. pascal ComponentResult SGGetChannelMaxFrames (SGChannel c, long *frameCount)  = {0x2F3C,0x4,0x8A,0x7000,0xA82A};
  304.  
  305. pascal ComponentResult SGSetChannelRefCon (SGChannel c, long refCon)  = {0x2F3C,0x4,0x8B,0x7000,0xA82A};
  306.  
  307. pascal ComponentResult SGSetChannelClip (SGChannel c, RgnHandle theClip)  = {0x2F3C,0x4,0x8C,0x7000,0xA82A};
  308.  
  309. pascal ComponentResult SGGetChannelClip (SGChannel c, RgnHandle *theClip)  = {0x2F3C,0x4,0x8D,0x7000,0xA82A};
  310.  
  311. pascal ComponentResult SGGetChannelSampleDescription (SGChannel c, Handle sampleDesc)  = {0x2F3C,0x4,0x8E,0x7000,0xA82A};
  312.  
  313. pascal ComponentResult SGGetChannelDeviceList (SGChannel c, long selectionFlags, SGDeviceList *list)  = {0x2F3C,0x8,0x8F,0x7000,0xA82A};
  314.  
  315. pascal ComponentResult SGSetChannelDevice (SGChannel c, StringPtr name)  = {0x2F3C,0x4,0x90,0x7000,0xA82A};
  316.  
  317. pascal ComponentResult SGSetChannelMatrix (SGChannel c, const MatrixRecord *m)  = {0x2F3C,0x4,0x91,0x7000,0xA82A};
  318.  
  319. pascal ComponentResult SGGetChannelMatrix (SGChannel c, MatrixRecord *m)  = {0x2F3C,0x4,0x92,0x7000,0xA82A};
  320.  
  321. pascal ComponentResult SGGetChannelTimeScale (SGChannel c, TimeScale *scale)  = {0x2F3C,0x4,0x93,0x7000,0xA82A};
  322.  
  323. pascal ComponentResult SGChannelPutPicture (SGChannel c)  = {0x2F3C,0,0x94,0x7000,0xA82A};
  324.  
  325. /*
  326.     calls from seqGrab to Channel
  327. */
  328.  
  329. pascal ComponentResult SGInitChannel (SGChannel c, SeqGrabComponent owner)  = {0x2F3C,0x4,0x180,0x7000,0xA82A};
  330. pascal ComponentResult SGWriteSamples (SGChannel c, Movie m, AliasHandle theFile)  = {0x2F3C,0x8,0x181,0x7000,0xA82A};
  331. pascal ComponentResult SGGetDataRate (SGChannel c, long *bytesPerSecond)  = {0x2F3C,0x4,0x182,0x7000,0xA82A};
  332. pascal ComponentResult SGAlignChannelRect (SGChannel c, Rect *r)  = {0x2F3C,0x4,0x183,0x7000,0xA82A};
  333.  
  334. /*
  335.     Dorky dialog panel calls
  336. */
  337.  
  338. pascal ComponentResult SGPanelGetDitl (SeqGrabComponent s, Handle *ditl)  = {0x2F3C,0x4,0x200,0x7000,0xA82A};
  339. pascal ComponentResult SGPanelGetTitle (SeqGrabComponent s, Str255 title)  = {0x2F3C,0x4,0x201,0x7000,0xA82A};
  340. pascal ComponentResult SGPanelCanRun (SeqGrabComponent s, SGChannel c)  = {0x2F3C,0x4,0x202,0x7000,0xA82A};
  341. pascal ComponentResult SGPanelInstall (SeqGrabComponent s, SGChannel c, DialogPtr d, short itemOffset)  = {0x2F3C,0xA,0x203,0x7000,0xA82A};
  342. pascal ComponentResult SGPanelEvent (SeqGrabComponent s, SGChannel c, DialogPtr d, short itemOffset,
  343.         EventRecord *theEvent, short *itemHit, Boolean *handled)  = {0x2F3C,0x16,0x204,0x7000,0xA82A};
  344. pascal ComponentResult SGPanelItem (SeqGrabComponent s, SGChannel c, DialogPtr d, short itemOffset, short itemNum)  = {0x2F3C,0xC,0x205,0x7000,0xA82A};
  345. pascal ComponentResult SGPanelRemove (SeqGrabComponent s, SGChannel c, DialogPtr d, short itemOffset)  = {0x2F3C,0xA,0x206,0x7000,0xA82A};
  346. pascal ComponentResult SGPanelSetGrabber (SeqGrabComponent s, SeqGrabComponent sg)  = {0x2F3C,0x4,0x207,0x7000,0xA82A};
  347. pascal ComponentResult SGPanelSetResFile (SeqGrabComponent s, short resRef)  = {0x2F3C,0x2,0x208,0x7000,0xA82A};
  348. pascal ComponentResult SGPanelGetSettings (SeqGrabComponent s, SGChannel c, UserData *ud, long flags)  = {0x2F3C,0xC,0x209,0x7000,0xA82A};
  349. pascal ComponentResult SGPanelSetSettings (SeqGrabComponent s, SGChannel c, UserData ud, long flags)  = {0x2F3C,0xC,0x20A,0x7000,0xA82A};
  350. pascal ComponentResult SGPanelValidateInput (SeqGrabComponent s, Boolean *ok)  = {0x2F3C,0x4,0x20B,0x7000,0xA82A};
  351. #ifdef __cplusplus
  352. }
  353. #endif __cplusplus
  354.  
  355.  
  356. /*** Sequence Grab VIDEO CHANNEL Component Stuff ***/
  357.  
  358. /*
  359.     Video stuff
  360. */
  361.  
  362.     typedef struct SGCompressInfo {
  363.         Ptr                buffer;
  364.         unsigned long    bufferSize;
  365.         unsigned char    similarity;
  366.         unsigned char    reserved;
  367.     } SGCompressInfo;
  368.  
  369. typedef pascal ComponentResult (*GrabProc)(SGChannel c, short bufferNum, long refCon);
  370. typedef pascal ComponentResult (*GrabCompleteProc)(SGChannel c, short bufferNum, Boolean *done, long refCon);
  371.  
  372. typedef pascal ComponentResult (*DisplayProc)(SGChannel c, short bufferNum, MatrixRecord *mp, RgnHandle clipRgn, long refCon);
  373.  
  374. typedef pascal ComponentResult (*CompressProc)(SGChannel c, short bufferNum, long refCon);
  375. typedef pascal ComponentResult (*CompressCompleteProc)(SGChannel c, short bufferNum,
  376.                                         Boolean *done, SGCompressInfo *ci, long refCon);
  377.  
  378. typedef pascal ComponentResult (*AddFrameProc)(SGChannel c, short bufferNum, TimeValue atTime, TimeScale scale,
  379.                             const SGCompressInfo *ci, long refCon);
  380.  
  381. typedef pascal ComponentResult (*TransferFrameProc)(SGChannel c, short bufferNum, MatrixRecord *mp, RgnHandle clipRgn, long refCon);
  382.  
  383. typedef pascal ComponentResult (*GrabCompressCompleteProc)(SGChannel c, Boolean *done, SGCompressInfo *ci, TimeRecord *t, long refCon);
  384. typedef pascal ComponentResult (*DisplayCompressProc)(SGChannel c, Ptr dataPtr, ImageDescriptionHandle desc, MatrixRecord *mp, RgnHandle clipRgn, long refCon);
  385.  
  386.     struct VideoBottles {
  387.         short                        procCount;
  388.         GrabProc                    grabProc;
  389.         GrabCompleteProc            grabCompleteProc;
  390.         DisplayProc                    displayProc;
  391.         CompressProc                compressProc;
  392.         CompressCompleteProc        compressCompleteProc;
  393.         AddFrameProc                addFrameProc;
  394.         TransferFrameProc            transferFrameProc;
  395.         GrabCompressCompleteProc    grabCompressCompleteProc;
  396.         DisplayCompressProc            displayCompressProc;
  397.     };
  398.     typedef struct VideoBottles VideoBottles;
  399.  
  400.  
  401. #ifdef __cplusplus
  402. extern "C" {
  403. #endif __cplusplus
  404.  
  405. pascal ComponentResult SGGetSrcVideoBounds (SGChannel c, Rect *r)  = {0x2F3C,0x4,0x100,0x7000,0xA82A};
  406. pascal ComponentResult SGSetVideoRect (SGChannel c, Rect *r)  = {0x2F3C,0x4,0x101,0x7000,0xA82A};
  407. pascal ComponentResult SGGetVideoRect (SGChannel c, Rect *r)  = {0x2F3C,0x4,0x102,0x7000,0xA82A};
  408.  
  409. pascal ComponentResult SGGetVideoCompressorType (SGChannel c, OSType *compressorType)  = {0x2F3C,0x4,0x103,0x7000,0xA82A};
  410. pascal ComponentResult SGSetVideoCompressorType (SGChannel c, OSType compressorType)  = {0x2F3C,0x4,0x104,0x7000,0xA82A};
  411.  
  412. pascal ComponentResult SGSetVideoCompressor (SGChannel c, short depth, CompressorComponent compressor,
  413.             CodecQ spatialQuality, CodecQ temporalQuality, long keyFrameRate)  = {0x2F3C,0x12,0x105,0x7000,0xA82A};
  414. pascal ComponentResult SGGetVideoCompressor (SGChannel c, short *depth, CompressorComponent *compressor,
  415.             CodecQ *spatialQuality, CodecQ *temporalQuality, long *keyFrameRate)  = {0x2F3C,0x14,0x106,0x7000,0xA82A};
  416.  
  417. pascal ComponentInstance SGGetVideoDigitizerComponent (SGChannel c)  = {0x2F3C,0,0x107,0x7000,0xA82A};
  418. pascal ComponentResult SGSetVideoDigitizerComponent (SGChannel c, ComponentInstance vdig)  = {0x2F3C,0x4,0x108,0x7000,0xA82A};
  419. pascal ComponentResult SGVideoDigitizerChanged (SGChannel c)  = {0x2F3C,0,0x109,0x7000,0xA82A};
  420.  
  421. pascal ComponentResult SGSetVideoBottlenecks (SGChannel c, VideoBottles *vb)  = {0x2F3C,0x4,0x10A,0x7000,0xA82A};
  422. pascal ComponentResult SGGetVideoBottlenecks (SGChannel c, VideoBottles *vb)  = {0x2F3C,0x4,0x10B,0x7000,0xA82A};
  423.  
  424. pascal ComponentResult SGGrabFrame (SGChannel c, short bufferNum)  = {0x2F3C,0x2,0x10C,0x7000,0xA82A};
  425. pascal ComponentResult SGGrabFrameComplete (SGChannel c, short bufferNum, Boolean *done)  = {0x2F3C,0x6,0x10D,0x7000,0xA82A};
  426. pascal ComponentResult SGDisplayFrame (SGChannel c, short bufferNum, MatrixRecord *mp, RgnHandle clipRgn)  = {0x2F3C,0xA,0x10E,0x7000,0xA82A};
  427.  
  428. pascal ComponentResult SGCompressFrame (SGChannel c, short bufferNum)  = {0x2F3C,0x2,0x10F,0x7000,0xA82A};
  429. pascal ComponentResult SGCompressFrameComplete (SGChannel c, short bufferNum, Boolean *done, SGCompressInfo *ci)  = {0x2F3C,0xA,0x110,0x7000,0xA82A};
  430.  
  431. pascal ComponentResult SGAddFrame (SGChannel c, short bufferNum, TimeValue atTime, TimeScale scale, const SGCompressInfo *ci)  = {0x2F3C,0xE,0x111,0x7000,0xA82A};
  432.  
  433. pascal ComponentResult SGTransferFrameForCompress (SGChannel c, short bufferNum, MatrixRecord *mp, RgnHandle clipRgn)  = {0x2F3C,0xA,0x112,0x7000,0xA82A};
  434.  
  435. pascal ComponentResult SGSetCompressBuffer (SGChannel c, short depth, const Rect *compressSize)  = {0x2F3C,0x6,0x113,0x7000,0xA82A};
  436.  
  437. pascal ComponentResult SGGetCompressBuffer (SGChannel c, short *depth, Rect *compressSize)  = {0x2F3C,0x8,0x114,0x7000,0xA82A};
  438.  
  439. pascal ComponentResult SGGetBufferInfo (SGChannel c, short bufferNum, 
  440.                     PixMapHandle *bufferPM, Rect *bufferRect,
  441.                     GWorldPtr *compressBuffer, Rect *compressBufferRect)  = {0x2F3C,0x12,0x115,0x7000,0xA82A};
  442.  
  443. pascal ComponentResult SGSetUseScreenBuffer (SGChannel c, Boolean useScreenBuffer)  = {0x2F3C,0x2,0x116,0x7000,0xA82A};
  444.  
  445. pascal ComponentResult SGGetUseScreenBuffer (SGChannel c, Boolean *useScreenBuffer)  = {0x2F3C,0x4,0x117,0x7000,0xA82A};
  446.  
  447. pascal ComponentResult SGGrabCompressComplete (SGChannel c, Boolean *done, SGCompressInfo *ci, TimeRecord *tr)  = {0x2F3C,0xC,0x118,0x7000,0xA82A};
  448. pascal ComponentResult SGDisplayCompress (SGChannel c, Ptr dataPtr, ImageDescriptionHandle desc, MatrixRecord *mp, RgnHandle clipRgn)  = {0x2F3C,0x10,0x119,0x7000,0xA82A};
  449.  
  450. pascal ComponentResult SGSetFrameRate (SGChannel c, Fixed frameRate)  = {0x2F3C,0x4,0x11A,0x7000,0xA82A};
  451.  
  452. pascal ComponentResult SGGetFrameRate (SGChannel c, Fixed *frameRate)  = {0x2F3C,0x4,0x11B,0x7000,0xA82A};
  453.  
  454.  
  455.  
  456. #ifdef __cplusplus
  457. }
  458. #endif __cplusplus
  459.  
  460.  
  461. /*** Sequence Grab SOUND CHANNEL Component Stuff ***/
  462.  
  463.  
  464. /*
  465.     Sound stuff
  466. */
  467.  
  468. #ifdef __cplusplus
  469. extern "C" {
  470. #endif __cplusplus
  471.  
  472. pascal ComponentResult SGSetSoundInputDriver (SGChannel c, const Str255 driverName)  = {0x2F3C,0x4,0x100,0x7000,0xA82A};
  473. pascal long SGGetSoundInputDriver (SGChannel c)  = {0x2F3C,0,0x101,0x7000,0xA82A};
  474. pascal ComponentResult SGSoundInputDriverChanged (SGChannel c)  = {0x2F3C,0,0x102,0x7000,0xA82A};
  475.  
  476. pascal ComponentResult SGSetSoundRecordChunkSize (SGChannel c, long seconds)  = {0x2F3C,0x4,0x103,0x7000,0xA82A};
  477. pascal long SGGetSoundRecordChunkSize (SGChannel c)  = {0x2F3C,0,0x104,0x7000,0xA82A};
  478.  
  479. pascal ComponentResult SGSetSoundInputRate (SGChannel c, Fixed rate)  = {0x2F3C,0x4,0x105,0x7000,0xA82A};
  480. pascal Fixed SGGetSoundInputRate (SGChannel c)  = {0x2F3C,0,0x106,0x7000,0xA82A};
  481.  
  482. pascal ComponentResult SGSetSoundInputParameters (SGChannel c, short sampleSize, short numChannels,
  483.                         OSType compressionType)  = {0x2F3C,0x8,0x107,0x7000,0xA82A};
  484. pascal ComponentResult SGGetSoundInputParameters (SGChannel c, short *sampleSize, short *numChannels,
  485.                         OSType *compressionType)  = {0x2F3C,0xC,0x108,0x7000,0xA82A};
  486. #ifdef __cplusplus
  487. }
  488. #endif __cplusplus
  489.  
  490.  
  491. #define sgChannelAtom 'chan'
  492.  
  493. #define sgChannelSettingsAtom 'ctom'
  494. #define sgChannelDescription 'cdsc'
  495. #define sgChannelSettings 'cset'
  496.  
  497. #define sgDeviceNameType 'name'
  498. #define sgUsageType 'use '
  499. #define sgPlayFlagsType 'plyf'
  500. #define sgClipType 'clip'
  501. #define sgMatrixType 'mtrx'
  502. #define sgVolumeType 'volu'
  503.  
  504. #define sgPanelSettingsAtom 'ptom'
  505. #define sgPanelDescription 'pdsc'
  506. #define sgPanelSettings 'pset'
  507.  
  508. #define sgcSoundCompressionType 'scmp'
  509. #define sgcSoundSampleRateType 'srat'
  510. #define sgcSoundChannelCountType 'schn'
  511. #define sgcSoundSampleSizeType 'ssiz'
  512. #define sgcSoundInputType 'sinp'
  513. #define sgcSoundGainType 'gain'
  514.  
  515. #define sgcVideoHueType 'hue '
  516. #define sgcVideoSaturationType 'satr'
  517. #define sgcVideoContrastType 'trst'
  518. #define sgcVideoSharpnessType 'shrp'
  519. #define sgcVideoBrigtnessType 'brit'
  520. #define sgcVideoBlackLevelType 'blkl'
  521. #define sgcVideoWhiteLevelType 'whtl'
  522.  
  523. #define sgcVideoInputType 'vinp'
  524. #define sgcVideoFormatType 'vstd'
  525. #define sgcVideoFilterType 'vflt'
  526.  
  527. #define sgcVideoRectType 'vrct'
  528. #define sgVideoDigitizerType 'vdig'
  529.  
  530. enum {
  531.     noDeviceForChannel = -9400,
  532.     grabTimeComplete = -9401,
  533.     cantDoThatInCurrentMode = -9402,
  534.     notEnoughMemoryToGrab = -9403,
  535.     notEnoughDiskSpaceToGrab = -9404,
  536.     couldntGetRequiredComponent = -9405,
  537.     badSGChannel = -9406,
  538.     seqGrabInfoNotAvailable = -9407,
  539.     deviceCantMeetRequest = -9408
  540. };
  541.  
  542.  
  543. enum {
  544.     kSGInitializeSelect = 0x1,
  545.     kSGSetDataOutputSelect = 0x2,
  546.     kSGGetDataOutputSelect = 0x3,
  547.     kSGSetGWorldSelect = 0x4,
  548.     kSGGetGWorldSelect = 0x5,
  549.     kSGNewChannelSelect = 0x6,
  550.     kSGDisposeChannelSelect = 0x7,
  551.     kSGStartPreviewSelect = 0x10,
  552.     kSGStartRecordSelect = 0x11,
  553.     kSGIdleSelect = 0x12,
  554.     kSGStopSelect = 0x13,
  555.     kSGPauseSelect = 0x14,
  556.     kSGPrepareSelect = 0x15,
  557.     kSGReleaseSelect = 0x16,
  558.     kSGGetMovieSelect = 0x17,
  559.     kSGSetMaximumRecordTimeSelect = 0x18,
  560.     kSGGetMaximumRecordTimeSelect = 0x19,
  561.     kSGGetStorageSpaceRemainingSelect = 0x1A,
  562.     kSGGetTimeRemainingSelect = 0x1B,
  563.     kSGGrabPictSelect = 0x1C,
  564.     kSGGetLastMovieResIDSelect = 0x1D,
  565.     kSGSetFlagsSelect = 0x1E,
  566.     kSGGetFlagsSelect = 0x1F,
  567.     kSGSetDataProcSelect = 0x20,
  568.     kSGNewChannelFromComponentSelect = 0x21,
  569.     kSGDisposeDeviceListSelect = 0x22,
  570.     kSGAppendDeviceListToMenuSelect = 0x23,
  571.     kSGSetSettingsSelect = 0x24,
  572.     kSGGetSettingsSelect = 0x25,
  573.     kSGGetIndChannelSelect = 0x26,
  574.     kSGUpdateSelect = 0x27,
  575.     kSGGetPauseSelect = 0x28,
  576.     kSGSettingsDialogSelect = 0x29,
  577.     kSGGetAlignmentProcSelect = 0x2A,
  578.     kSGSetChannelSettingsSelect = 0x2B,
  579.     kSGGetChannelSettingsSelect = 0x2C,
  580.     kSGWriteMovieDataSelect = 0x100,
  581.     kSGAddFrameReferenceSelect = 0x101,
  582.     kSGGetNextFrameReferenceSelect = 0x102,
  583.     kSGGetTimeBaseSelect = 0x103,
  584.     kSGSortDeviceListSelect = 0x104,
  585.     kSGAddMovieDataSelect = 0x105,
  586.     kSGChangedSourceSelect = 0x106,
  587.     kSGCSetChannelUsageSelect = 0x80,
  588.     kSGCGetChannelUsageSelect = 0x81,
  589.     kSGCSetChannelBoundsSelect = 0x82,
  590.     kSGCGetChannelBoundsSelect = 0x83,
  591.     kSGCSetChannelVolumeSelect = 0x84,
  592.     kSGCGetChannelVolumeSelect = 0x85,
  593.     kSGCGetChannelInfoSelect = 0x86,
  594.     kSGCSetChannelPlayFlagsSelect = 0x87,
  595.     kSGCGetChannelPlayFlagsSelect = 0x88,
  596.     kSGCSetChannelMaxFramesSelect = 0x89,
  597.     kSGCGetChannelMaxFramesSelect = 0x8A,
  598.     kSGCSetChannelRefConSelect = 0x8B,
  599.     kSGCSetChannelClipSelect = 0x8C,
  600.     kSGCGetChannelClipSelect = 0x8D,
  601.     kSGCGetChannelSampleDescriptionSelect = 0x8E,
  602.     kSGCGetChannelDeviceListSelect = 0x8F,
  603.     kSGCSetChannelDeviceSelect = 0x90,
  604.     kSGCSetChannelMatrixSelect = 0x91,
  605.     kSGCGetChannelMatrixSelect = 0x92,
  606.     kSGCGetChannelTimeScaleSelect = 0x93,
  607.     kSGCChannelPutPictureSelect = 0x94,
  608.     kSGCInitChannelSelect = 0x180,
  609.     kSGCWriteSamplesSelect = 0x181,
  610.     kSGCGetDataRateSelect = 0x182,
  611.     kSGCAlignChannelRectSelect = 0x183,
  612.     kSGCPanelGetDitlSelect = 0x200,
  613.     kSGCPanelGetTitleSelect = 0x201,
  614.     kSGCPanelCanRunSelect = 0x202,
  615.     kSGCPanelInstallSelect = 0x203,
  616.     kSGCPanelEventSelect = 0x204,
  617.     kSGCPanelItemSelect = 0x205,
  618.     kSGCPanelRemoveSelect = 0x206,
  619.     kSGCPanelSetGrabberSelect = 0x207,
  620.     kSGCPanelSetResFileSelect = 0x208,
  621.     kSGCPanelGetSettingsSelect = 0x209,
  622.     kSGCPanelSetSettingsSelect = 0x20A,
  623.     kSGCPanelValidateInputSelect = 0x20B,
  624.     kSGCGetSrcVideoBoundsSelect = 0x100,
  625.     kSGCSetVideoRectSelect = 0x101,
  626.     kSGCGetVideoRectSelect = 0x102,
  627.     kSGCGetVideoCompressorTypeSelect = 0x103,
  628.     kSGCSetVideoCompressorTypeSelect = 0x104,
  629.     kSGCSetVideoCompressorSelect = 0x105,
  630.     kSGCGetVideoCompressorSelect = 0x106,
  631.     kSGCGetVideoDigitizerComponentSelect = 0x107,
  632.     kSGCSetVideoDigitizerComponentSelect = 0x108,
  633.     kSGCVideoDigitizerChangedSelect = 0x109,
  634.     kSGCSetVideoBottlenecksSelect = 0x10A,
  635.     kSGCGetVideoBottlenecksSelect = 0x10B,
  636.     kSGCGrabFrameSelect = 0x10C,
  637.     kSGCGrabFrameCompleteSelect = 0x10D,
  638.     kSGCDisplayFrameSelect = 0x10E,
  639.     kSGCCompressFrameSelect = 0x10F,
  640.     kSGCCompressFrameCompleteSelect = 0x110,
  641.     kSGCAddFrameSelect = 0x111,
  642.     kSGCTransferFrameForCompressSelect = 0x112,
  643.     kSGCSetCompressBufferSelect = 0x113,
  644.     kSGCGetCompressBufferSelect = 0x114,
  645.     kSGCGetBufferInfoSelect = 0x115,
  646.     kSGCSetUseScreenBufferSelect = 0x116,
  647.     kSGCGetUseScreenBufferSelect = 0x117,
  648.     kSGCGrabCompressCompleteSelect = 0x118,
  649.     kSGCDisplayCompressSelect = 0x119,
  650.     kSGCSetFrameRateSelect = 0x11A,
  651.     kSGCGetFrameRateSelect = 0x11B,
  652.     kSGCSetSoundInputDriverSelect = 0x100,
  653.     kSGCGetSoundInputDriverSelect = 0x101,
  654.     kSGCSoundInputDriverChangedSelect = 0x102,
  655.     kSGCSetSoundRecordChunkSizeSelect = 0x103,
  656.     kSGCGetSoundRecordChunkSizeSelect = 0x104,
  657.     kSGCSetSoundInputRateSelect = 0x105,
  658.     kSGCGetSoundInputRateSelect = 0x106,
  659.     kSGCSetSoundInputParametersSelect = 0x107,
  660.     kSGCGetSoundInputParametersSelect = 0x108 
  661. };
  662.  
  663. /* Standard type for video digitizers */
  664.  
  665. #define    videoDigitizerComponentType        'vdig'        
  666. #define vdigInterfaceRev                2L
  667.  
  668. /* Input Format Standards */
  669.  
  670. #define    ntscIn            0                /* current input format */
  671. #define    currentIn        0                /* ntsc input format */
  672. #define    palIn            1                /* pal input format */
  673. #define    secamIn            2                /* secam input format */
  674. #define    ntscReallyIn    3                /* ntsc input format */
  675.  
  676. /* Input Formats */
  677.  
  678. #define    compositeIn        0                /* input is composite format */
  679. #define    sVideoIn        1                /* input is sVideo format */
  680. #define rgbComponentIn    2                /* input is rgb component format */
  681.  
  682. /* Video Digitizer PlayThru States */
  683.  
  684. #define vdPlayThruOff        0
  685. #define vdPlayThruOn        1
  686.  
  687. /* Input Color Space Modes */
  688.  
  689. #define vdDigitizerBW        0            /* black and white */
  690. #define vdDigitizerRGB        1            /* rgb color */
  691.  
  692. /* Phase Lock Loop Modes */
  693.  
  694. #define vdBroadcastMode        0            /* Broadcast / Laser Disk video mode */
  695. #define vdVTRMode            1            /* VCR / Magnetic media mode */
  696.  
  697. /* Field Select Options */
  698. #define vdUseAnyField 0                    /* Digitizers choice on field use */
  699. #define vdUseOddField 1                    /* Use odd field for half size vert and smaller */
  700. #define vdUseEvenField 2                /* Use even field for half size vert and smaller */
  701.  
  702. /* vdig types */
  703.  
  704. #define vdTypeBasic            0            /* basic, no clipping */
  705. #define vdTypeAlpha            1            /* supports clipping with alpha channel */
  706. #define vdTypeMask            2            /* supports clipping with mask plane */
  707. #define vdTypeKey            3            /* supports clipping with key color(s) */
  708.  
  709. /* Digitizer Error Codes */
  710.  
  711. #define    digiUnimpErr    -2201             /* feature unimplemented */
  712. #define    qtParamErr        -2202            /* bad input parameter (out of range, etc) */
  713. #define    matrixErr        -2203            /* bad matrix, digitizer did nothing */
  714. #define    notExactMatrix    -2204            /* warning of bad matrix, digitizer did its best */
  715. #define    noMoreKeyColors    -2205            /* all key indexes in use */
  716. #define    notExactSize    -2206            /* Can’t do exact size requested */
  717. #define    badDepth        -2207            /* Can’t digitize into this depth */
  718. #define    noDMA            -2208            /* Can’t do DMA digitizing (i.e. can't go to requested dest */
  719. #define badCallOrder    -2209            /* Usually due to a status call being called prior to being setup first */
  720.  
  721. /* Digitizer Input Capability/Current Flags    */
  722.  
  723. #define    digiInDoesNTSC        (1L<<0)        /* digitizer supports NTSC input format */
  724. #define    digiInDoesPAL        (1L<<1)        /* digitizer supports PAL input format */
  725. #define    digiInDoesSECAM        (1L<<2)        /* digitizer supports SECAM input format */
  726. #define digiInDoesGenLock    (1L<<7)        /* digitizer does genlock */
  727.  
  728. #define    digiInDoesComposite    (1L<<8)        /* digitizer supports composite input type */
  729. #define    digiInDoesSVideo    (1L<<9)        /* digitizer supports S-Video input type */
  730. #define digiInDoesComponent (1L<<10)    /* digitizer supports component (rgb) input type */
  731. #define    digiInVTR_Broadcast    (1L<<11)    /* digitizer can differentiate between the two */
  732.  
  733. #define    digiInDoesColor        (1L<<12)    /* digitizer supports color */
  734. #define    digiInDoesBW        (1L<<13)    /* digitizer supports black & white */
  735.  
  736. /* Digitizer Input Current Flags (these are valid only during active operating conditions)    */
  737.  
  738. #define    digiInSignalLock    (1L<<31)    /* digitizer detects input signal is locked */
  739.                                         /* this bit = horiz lock || vertical lock */
  740.  
  741. /* Digitizer Output Capability/Current Flags */
  742.  
  743. #define    digiOutDoes1            (1L<<0)        /* digitizer supports 1 bit pixels */
  744. #define    digiOutDoes2            (1L<<1)        /* digitizer supports 2 bit pixels */
  745. #define    digiOutDoes4            (1L<<2)        /* digitizer supports 4 bit pixels */
  746. #define    digiOutDoes8            (1L<<3)        /* digitizer supports 8 bit pixels */
  747. #define    digiOutDoes16            (1L<<4)        /* digitizer supports 16 bit pixels */
  748. #define    digiOutDoes32            (1L<<5)        /* digitizer supports 32 bit pixels */
  749. #define    digiOutDoesDither        (1L<<6)        /* digitizer dithers in indexed modes */
  750. #define    digiOutDoesStretch        (1L<<7)        /* digitizer can arbitrarily stretch */
  751. #define    digiOutDoesShrink        (1L<<8)        /* digitizer can arbitrarily shrink */
  752. #define    digiOutDoesMask            (1L<<9)        /* digitizer can mask to clipping regions */
  753.  
  754. #define    digiOutDoesDouble        (1L<<11)    /* digitizer can stretch to exactly double size */
  755. #define    digiOutDoesQuad            (1L<<12)    /* digitizer can stretch exactly quadruple size */
  756. #define    digiOutDoesQuarter        (1L<<13)    /* digitizer can shrink to exactly quarter size */
  757. #define    digiOutDoesSixteenth    (1L<<14)    /* digitizer can shrink to exactly sixteenth size */
  758.  
  759. #define    digiOutDoesRotate        (1L<<15)    /* digitizer supports rotate transformations */
  760. #define    digiOutDoesHorizFlip    (1L<<16)    /* digitizer supports horizontal flips Sx < 0 */
  761. #define    digiOutDoesVertFlip        (1L<<17)    /* digitizer supports vertical flips Sy < 0 */
  762. #define    digiOutDoesSkew            (1L<<18)    /* digitizer supports skew (shear,twist) */
  763. #define    digiOutDoesBlend        (1L<<19)
  764. #define    digiOutDoesWarp            (1L<<20)
  765.  
  766. #define    digiOutDoesHW_DMA        (1L<<21)    /* digitizer not constrained to local device */
  767. #define digiOutDoesHWPlayThru    (1L<<22)    /* digitizer doesn't need time to play thru */
  768. #define    digiOutDoesILUT            (1L<<23)    /* digitizer does inverse LUT for index modes */
  769. #define    digiOutDoesKeyColor        (1L<<24)    /* digitizer does key color functions too */
  770. #define digiOutDoesAsyncGrabs    (1L<<25)    /* digitizer supports async grabs */
  771. #define digiOutDoesUnreadableScreenBits (1L<<26)    /* playthru doesn't generate readable bits on screen*/
  772. #define digiOutDoesCompress        (1L<<27)    /* supports alternate output data types */
  773. #define digiOutDoesCompressOnly    (1L<<28)    /* can't provide raw frames anywhere */
  774. #define digiOutDoesPlayThruDuringCompress (1L<<29)    /* digi can do playthru while providing compressed data */
  775.  
  776. /* Types */
  777.  
  778. typedef ComponentInstance VideoDigitizerComponent;
  779. typedef ComponentResult VideoDigitizerError;
  780.  
  781. typedef struct {
  782.     short        vdigType;
  783.     long         inputCapabilityFlags;
  784.     long         outputCapabilityFlags;    
  785.     long         inputCurrentFlags;
  786.     long         outputCurrentFlags;
  787.     short        slot;                    /* temporary for connection purposes */
  788.     GDHandle    gdh;                    /* temporary for digitizers that have preferred screen */
  789.     GDHandle    maskgdh;                /* temporary for digitizers that have mask planes */
  790.     short        minDestHeight;            /* Smallest resizable height */        
  791.     short        minDestWidth;            /* Smallest resizable width */
  792.     short        maxDestHeight;            /* Largest resizable height */
  793.     short        maxDestWidth;            /* Largest resizable height */
  794.     short        blendLevels;            /* Number of blend levels supported (2 if 1 bit mask) */
  795.     long        reserved;                /* reserved */
  796. } DigitizerInfo;
  797.  
  798. typedef struct {
  799.     long        type;
  800.     long        reserved;
  801. } VdigType;
  802.  
  803. typedef struct {
  804.     short        count;
  805.     VdigType    list[1];
  806. } VdigTypeList;
  807.  
  808. typedef struct {
  809.     PixMapHandle    dest;
  810.     Point            location;
  811.     long            reserved;
  812. } VdigBufferRec;
  813.  
  814. typedef struct {
  815.     short            count;
  816.     MatrixRecordPtr    matrix;
  817.     RgnHandle        mask;
  818.     VdigBufferRec    list[1];
  819. } VdigBufferRecList;
  820.  
  821. typedef VdigBufferRecList *VdigBufferRecListPtr, **VdigBufferRecListHandle;
  822.  
  823. typedef pascal void (*VdigIntProc)(long flags, long refcon);
  824.  
  825. typedef struct VDCompressionList {
  826.     CodecComponent        codec;
  827.     CodecType            cType;
  828.     Str63                typeName;
  829.     Str63                name;
  830.     long                formatFlags;
  831.     long                compressFlags;
  832.     long                reserved;
  833. } VDCompressionList, *VDCompressionListPtr, **VDCompressionListHandle;
  834.  
  835. enum {
  836.     dmaDepth1 = 1,
  837.     dmaDepth2 = 2,
  838.     dmaDepth4 = 4 ,
  839.     dmaDepth8 = 8,
  840.     dmaDepth16 = 16,
  841.     dmaDepth32 = 32,
  842.     dmaDepth2Gray = 64,
  843.     dmaDepth4Gray = 128,
  844.     dmaDepth8Gray = 256
  845. };
  846.  
  847. #define kVDIGControlledFrameRate (-1)
  848.  
  849.  
  850. // number of vdig calls
  851. enum {
  852.     kvdigSelectors = 82
  853. };
  854.  
  855. #ifdef __cplusplus
  856. extern "C" {
  857. #endif __cplusplus
  858. pascal VideoDigitizerError VDGetMaxSrcRect(VideoDigitizerComponent ci, short inputStd, Rect *maxSrcRect)     = {0x2F3C,0x6,0x1,0x7000,0xA82A};
  859.     
  860. pascal VideoDigitizerError VDGetActiveSrcRect(VideoDigitizerComponent ci, short inputStd, Rect *activeSrcRect)     = {0x2F3C,0x6,0x2,0x7000,0xA82A};
  861.     
  862. pascal VideoDigitizerError VDSetDigitizerRect(VideoDigitizerComponent ci, Rect *digitizerRect)     = {0x2F3C,0x4,0x3,0x7000,0xA82A};
  863.     
  864. pascal VideoDigitizerError VDGetDigitizerRect(VideoDigitizerComponent ci, Rect *digitizerRect)     = {0x2F3C,0x4,0x4,0x7000,0xA82A};
  865.     
  866. pascal VideoDigitizerError VDGetVBlankRect(VideoDigitizerComponent ci, short inputStd, Rect *vBlankRect)     = {0x2F3C,0x6,0x5,0x7000,0xA82A};
  867.     
  868. pascal VideoDigitizerError VDGetMaskPixMap(VideoDigitizerComponent ci, PixMapHandle maskPixMap)     = {0x2F3C,0x4,0x6,0x7000,0xA82A};
  869.     
  870. pascal VideoDigitizerError VDGetPlayThruDestination(VideoDigitizerComponent ci, PixMapHandle *dest, Rect *destRect,
  871.              MatrixRecord *m, RgnHandle *mask)     = {0x2F3C,0x10,0x8,0x7000,0xA82A};
  872.     
  873. pascal VideoDigitizerError VDUseThisCLUT(VideoDigitizerComponent ci, CTabHandle colorTableHandle)     = {0x2F3C,0x4,0x9,0x7000,0xA82A};        
  874.     
  875. pascal VideoDigitizerError VDSetInputGammaValue(VideoDigitizerComponent ci, Fixed channel1, Fixed channel2, Fixed channel3)     = {0x2F3C,0xC,0xA,0x7000,0xA82A};
  876.     
  877. pascal VideoDigitizerError VDGetInputGammaValue(VideoDigitizerComponent ci, Fixed *channel1, Fixed *channel2, Fixed *channel3)     = {0x2F3C,0xC,0xB,0x7000,0xA82A};
  878.     
  879. pascal VideoDigitizerError VDSetBrightness(VideoDigitizerComponent ci, unsigned short *brightness)     = {0x2F3C,0x4,0xC,0x7000,0xA82A};
  880.     
  881. pascal VideoDigitizerError VDGetBrightness(VideoDigitizerComponent ci, unsigned short *brightness)     = {0x2F3C,0x4,0xD,0x7000,0xA82A};
  882.     
  883. pascal VideoDigitizerError VDSetContrast(VideoDigitizerComponent ci, unsigned short *contrast)     = {0x2F3C,0x4,0xE,0x7000,0xA82A};
  884.     
  885. pascal VideoDigitizerError VDSetHue(VideoDigitizerComponent ci, unsigned short *hue)     = {0x2F3C,0x4,0xF,0x7000,0xA82A};
  886.     
  887. pascal VideoDigitizerError VDSetSharpness(VideoDigitizerComponent ci, unsigned short *sharpness)     = {0x2F3C,0x4,0x10,0x7000,0xA82A};
  888.     
  889. pascal VideoDigitizerError VDSetSaturation(VideoDigitizerComponent ci, unsigned short *saturation)     = {0x2F3C,0x4,0x11,0x7000,0xA82A};
  890.     
  891. pascal VideoDigitizerError VDGetContrast(VideoDigitizerComponent ci, unsigned short *contrast)     = {0x2F3C,0x4,0x12,0x7000,0xA82A};
  892.     
  893. pascal VideoDigitizerError VDGetHue(VideoDigitizerComponent ci, unsigned short *hue)     = {0x2F3C,0x4,0x13,0x7000,0xA82A};
  894.     
  895. pascal VideoDigitizerError VDGetSharpness(VideoDigitizerComponent ci, unsigned short *sharpness)     = {0x2F3C,0x4,0x14,0x7000,0xA82A};
  896.     
  897. pascal VideoDigitizerError VDGetSaturation(VideoDigitizerComponent ci, unsigned short *saturation)     = {0x2F3C,0x4,0x15,0x7000,0xA82A};
  898.     
  899. pascal VideoDigitizerError VDGrabOneFrame(VideoDigitizerComponent ci)     = {0x2F3C,0,0x16,0x7000,0xA82A};
  900.     
  901. pascal VideoDigitizerError VDGetMaxAuxBuffer(VideoDigitizerComponent ci, PixMapHandle *pm, Rect *r)     = {0x2F3C,0x8,0x17,0x7000,0xA82A};
  902.     
  903. pascal VideoDigitizerError VDGetDigitizerInfo(VideoDigitizerComponent ci, DigitizerInfo *info)     = {0x2F3C,0x4,0x19,0x7000,0xA82A};
  904.     
  905. pascal VideoDigitizerError VDGetCurrentFlags(VideoDigitizerComponent ci, long *inputCurrentFlag, long *outputCurrentFlag)     = {0x2F3C,0x8,0x1A,0x7000,0xA82A};
  906.     
  907. pascal VideoDigitizerError VDSetKeyColor(VideoDigitizerComponent ci, long index)     = {0x2F3C,0x4,0x1B,0x7000,0xA82A};
  908.     
  909. pascal VideoDigitizerError VDGetKeyColor(VideoDigitizerComponent ci, long *index)     = {0x2F3C,0x4,0x1C,0x7000,0xA82A};
  910.     
  911. pascal VideoDigitizerError VDAddKeyColor(VideoDigitizerComponent ci, long *index)     = {0x2F3C,0x4,0x1D,0x7000,0xA82A};
  912.     
  913. pascal VideoDigitizerError VDGetNextKeyColor(VideoDigitizerComponent ci, long index)     = {0x2F3C,0x4,0x1E,0x7000,0xA82A};
  914.     
  915. pascal VideoDigitizerError VDSetKeyColorRange(VideoDigitizerComponent ci, RGBColor *minRGB, RGBColor *maxRGB)     = {0x2F3C,0x8,0x1F,0x7000,0xA82A};
  916.     
  917. pascal VideoDigitizerError VDGetKeyColorRange(VideoDigitizerComponent ci, RGBColor *minRGB, RGBColor *maxRGB)     = {0x2F3C,0x8,0x20,0x7000,0xA82A};
  918.     
  919. pascal VideoDigitizerError VDSetDigitizerUserInterrupt(VideoDigitizerComponent ci, long flags, VdigIntProc userInterruptProc, long refcon)     = {0x2F3C,0xC,0x21,0x7000,0xA82A};
  920.     
  921. pascal VideoDigitizerError VDSetInputColorSpaceMode(VideoDigitizerComponent ci, short colorSpaceMode)     = {0x2F3C,0x2,0x22,0x7000,0xA82A};
  922.     
  923. pascal VideoDigitizerError VDGetInputColorSpaceMode(VideoDigitizerComponent ci, short *colorSpaceMode)     = {0x2F3C,0x4,0x23,0x7000,0xA82A};
  924.     
  925. pascal VideoDigitizerError VDSetClipState(VideoDigitizerComponent ci, short clipEnable)     = {0x2F3C,0x2,0x24,0x7000,0xA82A};
  926.     
  927. pascal VideoDigitizerError VDGetClipState(VideoDigitizerComponent ci, short *clipEnable)     = {0x2F3C,0x4,0x25,0x7000,0xA82A};
  928.     
  929. pascal VideoDigitizerError VDSetClipRgn(VideoDigitizerComponent ci, RgnHandle clipRegion)     = {0x2F3C,0x4,0x26,0x7000,0xA82A};
  930.     
  931. pascal VideoDigitizerError VDClearClipRgn(VideoDigitizerComponent ci, RgnHandle clipRegion)     = {0x2F3C,0x4,0x27,0x7000,0xA82A};
  932.     
  933. pascal VideoDigitizerError VDGetCLUTInUse(VideoDigitizerComponent ci, CTabHandle *colorTableHandle)     = {0x2F3C,0x4,0x28,0x7000,0xA82A};        
  934.     
  935. pascal VideoDigitizerError VDSetPLLFilterType(VideoDigitizerComponent ci, short pllType)     = {0x2F3C,0x2,0x29,0x7000,0xA82A};
  936.     
  937. pascal VideoDigitizerError VDGetPLLFilterType(VideoDigitizerComponent ci, short *pllType)     = {0x2F3C,0x4,0x2A,0x7000,0xA82A};
  938.     
  939. pascal VideoDigitizerError VDGetMaskandValue(VideoDigitizerComponent ci, unsigned short blendLevel, long *mask, long *value )     = {0x2F3C,0xA,0x2B,0x7000,0xA82A};
  940.     
  941. pascal VideoDigitizerError VDSetMasterBlendLevel(VideoDigitizerComponent ci, unsigned short *blendLevel)     = {0x2F3C,0x4,0x2C,0x7000,0xA82A};
  942.     
  943. pascal VideoDigitizerError VDSetPlayThruDestination(VideoDigitizerComponent ci, PixMapHandle dest, Rect *destRect,
  944.                                 MatrixRecord *m, RgnHandle mask)     = {0x2F3C,0x10,0x2D,0x7000,0xA82A};
  945.     
  946. pascal VideoDigitizerError VDSetPlayThruOnOff(VideoDigitizerComponent ci, short state)     = {0x2F3C,0x2,0x2E,0x7000,0xA82A};
  947.  
  948. pascal VideoDigitizerError VDSetFieldPreference(VideoDigitizerComponent ci, short fieldFlag)     = {0x2F3C,0x2,0x2F,0x7000,0xA82A};
  949.  
  950. pascal VideoDigitizerError VDGetFieldPreference(VideoDigitizerComponent ci, short *fieldFlag)     = {0x2F3C,0x4,0x30,0x7000,0xA82A};
  951.     
  952. pascal VideoDigitizerError VDPreflightDestination(VideoDigitizerComponent ci, Rect *digitizerRect, PixMap **dest, 
  953.                                 Rect *destRect, MatrixRecord *m)     = {0x2F3C,0x10,0x32,0x7000,0xA82A};
  954.     
  955. pascal VideoDigitizerError VDPreflightGlobalRect(VideoDigitizerComponent ci, GrafPtr theWindow, Rect *globalRect)     = {0x2F3C,0x8,0x33,0x7000,0xA82A};
  956.     
  957. pascal VideoDigitizerError VDSetPlayThruGlobalRect(VideoDigitizerComponent ci, GrafPtr theWindow, Rect *globalRect)     = {0x2F3C,0x8,0x34,0x7000,0xA82A};
  958.     
  959. pascal VideoDigitizerError VDSetInputGammaRecord(VideoDigitizerComponent ci, VDGamRecPtr inputGammaPtr)     = {0x2F3C,0x4,0x35,0x7000,0xA82A};
  960.     
  961. pascal VideoDigitizerError VDGetInputGammaRecord(VideoDigitizerComponent ci, VDGamRecPtr *inputGammaPtr)     = {0x2F3C,0x4,0x36,0x7000,0xA82A};
  962.     
  963. pascal VideoDigitizerError VDSetBlackLevelValue(VideoDigitizerComponent ci, unsigned short *blackLevel)     = {0x2F3C,0x4,0x37,0x7000,0xA82A};
  964.     
  965. pascal VideoDigitizerError VDGetBlackLevelValue(VideoDigitizerComponent ci, unsigned short *blackLevel)     = {0x2F3C,0x4,0x38,0x7000,0xA82A};
  966.     
  967. pascal VideoDigitizerError VDSetWhiteLevelValue(VideoDigitizerComponent ci, unsigned short *whiteLevel)     = {0x2F3C,0x4,0x39,0x7000,0xA82A};
  968.     
  969. pascal VideoDigitizerError VDGetWhiteLevelValue(VideoDigitizerComponent ci, unsigned short *whiteLevel)     = {0x2F3C,0x4,0x3A,0x7000,0xA82A};
  970.     
  971. pascal VideoDigitizerError VDGetVideoDefaults(VideoDigitizerComponent ci, 
  972.         unsigned short *blackLevel, unsigned short *whiteLevel,
  973.         unsigned short *brightness, unsigned short *hue, unsigned short *saturation,
  974.         unsigned short *contrast, unsigned short *sharpness)     = {0x2F3C,0x1C,0x3B,0x7000,0xA82A};
  975.     
  976. pascal VideoDigitizerError VDGetNumberOfInputs(VideoDigitizerComponent ci, short *inputs)     = {0x2F3C,0x4,0x3C,0x7000,0xA82A};
  977.     
  978. pascal VideoDigitizerError VDGetInputFormat(VideoDigitizerComponent ci, short input, short *format)     = {0x2F3C,0x6,0x3D,0x7000,0xA82A};
  979.     
  980. pascal VideoDigitizerError VDSetInput(VideoDigitizerComponent ci, short input)     = {0x2F3C,0x2,0x3E,0x7000,0xA82A};
  981.     
  982. pascal VideoDigitizerError VDGetInput(VideoDigitizerComponent ci, short *input)     = {0x2F3C,0x4,0x3F,0x7000,0xA82A};
  983.     
  984. pascal VideoDigitizerError VDSetInputStandard(VideoDigitizerComponent ci, short inputStandard)     = {0x2F3C,0x2,0x40,0x7000,0xA82A};
  985.     
  986. pascal VideoDigitizerError VDSetupBuffers(VideoDigitizerComponent ci, VdigBufferRecListHandle bufferList)     = {0x2F3C,0x4,0x41,0x7000,0xA82A};
  987.     
  988. pascal VideoDigitizerError VDGrabOneFrameAsync(VideoDigitizerComponent ci, short buffer)     = {0x2F3C,0x2,0x42,0x7000,0xA82A};
  989.     
  990. pascal VideoDigitizerError VDDone(VideoDigitizerComponent ci, short buffer)     = {0x2F3C,0x2,0x43,0x7000,0xA82A};
  991.  
  992. pascal VideoDigitizerError VDSetCompression(VideoDigitizerComponent ci, OSType compressType, short depth, Rect *bounds,
  993.             CodecQ spatialQuality, CodecQ temporalQuality, long keyFrameRate)     = {0x2F3C,0x16,0x44,0x7000,0xA82A};
  994.  
  995. pascal VideoDigitizerError VDCompressOneFrameAsync(VideoDigitizerComponent ci )     = {0x2F3C,0,0x45,0x7000,0xA82A};
  996.  
  997. pascal VideoDigitizerError VDCompressDone(VideoDigitizerComponent ci, Boolean *done, Ptr *theData, long *dataSize, unsigned char *similarity, TimeRecord *t)     = {0x2F3C,0x14,0x46,0x7000,0xA82A};
  998.  
  999. pascal VideoDigitizerError VDReleaseCompressBuffer(VideoDigitizerComponent ci, Ptr bufferAddr)     = {0x2F3C,0x4,0x47,0x7000,0xA82A};
  1000.  
  1001. pascal VideoDigitizerError VDGetImageDescription(VideoDigitizerComponent ci, ImageDescriptionHandle desc)     = {0x2F3C,0x4,0x48,0x7000,0xA82A};
  1002.  
  1003. pascal VideoDigitizerError VDResetCompressSequence(VideoDigitizerComponent ci )     = {0x2F3C,0,0x49,0x7000,0xA82A};
  1004.  
  1005. pascal VideoDigitizerError VDSetCompressionOnOff(VideoDigitizerComponent ci, Boolean state)     = {0x2F3C,0x2,0x4A,0x7000,0xA82A};
  1006.  
  1007. pascal VideoDigitizerError VDGetCompressionTypes(VideoDigitizerComponent ci, VDCompressionListHandle h)     = {0x2F3C,0x4,0x4B,0x7000,0xA82A};
  1008.  
  1009. pascal VideoDigitizerError VDSetTimeBase(VideoDigitizerComponent ci, TimeBase t)     = {0x2F3C,0x4,0x4C,0x7000,0xA82A};
  1010.  
  1011. pascal VideoDigitizerError VDSetFrameRate(VideoDigitizerComponent ci, Fixed framesPerSecond)     = {0x2F3C,0x4,0x4D,0x7000,0xA82A};
  1012.  
  1013. pascal VideoDigitizerError VDGetDataRate(VideoDigitizerComponent ci, long *milliSecPerFrame, Fixed *framesPerSecond, long *bytesPerSecond)     = {0x2F3C,0xC,0x4E,0x7000,0xA82A};
  1014.  
  1015. pascal VideoDigitizerError VDGetSoundInputDriver(VideoDigitizerComponent ci, Str255 soundDriverName)     = {0x2F3C,0x4,0x4F,0x7000,0xA82A};
  1016.  
  1017. pascal VideoDigitizerError VDGetDMADepths(VideoDigitizerComponent ci, long *depthArray, long *preferredDepth)     = {0x2F3C,0x8,0x50,0x7000,0xA82A};
  1018.  
  1019. pascal VideoDigitizerError VDGetPreferredTimeScale(VideoDigitizerComponent ci, TimeScale *preferred)     = {0x2F3C,0x4,0x51,0x7000,0xA82A};
  1020.  
  1021. pascal VideoDigitizerError VDReleaseAsyncBuffers(VideoDigitizerComponent ci)     = {0x2F3C,0,0x52,0x7000,0xA82A};
  1022.  
  1023. #ifdef __cplusplus
  1024. }
  1025. #endif __cplusplus
  1026.  
  1027. enum {
  1028.     kSelectVDGetMaxSrcRect = 0x1,
  1029.     kSelectVDGetActiveSrcRect = 0x2,
  1030.     kSelectVDSetDigitizerRect = 0x3,
  1031.     kSelectVDGetDigitizerRect = 0x4,
  1032.     kSelectVDGetVBlankRect = 0x5,
  1033.     kSelectVDGetMaskPixMap = 0x6,
  1034.     kSelectVDGetPlayThruDestination = 0x8,
  1035.     kSelectVDUseThisCLUT = 0x9,        
  1036.     kSelectVDSetInputGammaValue = 0xA,
  1037.     kSelectVDGetInputGammaValue = 0xB,
  1038.     kSelectVDSetBrightness = 0xC,
  1039.     kSelectVDGetBrightness = 0xD,
  1040.     kSelectVDSetContrast = 0xE,
  1041.     kSelectVDSetHue = 0xF,
  1042.     kSelectVDSetSharpness = 0x10,
  1043.     kSelectVDSetSaturation = 0x11,
  1044.     kSelectVDGetContrast = 0x12,
  1045.     kSelectVDGetHue = 0x13,
  1046.     kSelectVDGetSharpness = 0x14,
  1047.     kSelectVDGetSaturation = 0x15,
  1048.     kSelectVDGrabOneFrame = 0x16,
  1049.     kSelectVDGetMaxAuxBuffer = 0x17,
  1050.     kSelectVDGetDigitizerInfo = 0x19,
  1051.     kSelectVDGetCurrentFlags = 0x1A,
  1052.     kSelectVDSetKeyColor = 0x1B,
  1053.     kSelectVDGetKeyColor = 0x1C,
  1054.     kSelectVDAddKeyColor = 0x1D,
  1055.     kSelectVDGetNextKeyColor = 0x1E,
  1056.     kSelectVDSetKeyColorRange = 0x1F,
  1057.     kSelectVDGetKeyColorRange = 0x20,
  1058.     kSelectVDSetDigitizerUserInterrupt = 0x21,
  1059.     kSelectVDSetInputColorSpaceMode = 0x22,
  1060.     kSelectVDGetInputColorSpaceMode = 0x23,
  1061.     kSelectVDSetClipState = 0x24,
  1062.     kSelectVDGetClipState = 0x25,
  1063.     kSelectVDSetClipRgn = 0x26,
  1064.     kSelectVDClearClipRgn = 0x27,
  1065.     kSelectVDGetCLUTInUse = 0x28,        
  1066.     kSelectVDSetPLLFilterType = 0x29,
  1067.     kSelectVDGetPLLFilterType = 0x2A,
  1068.     kSelectVDGetMaskandValue = 0x2B,
  1069.     kSelectVDSetMasterBlendLevel = 0x2C,
  1070.     kSelectVDSetPlayThruDestination = 0x2D,
  1071.     kSelectVDSetPlayThruOnOff = 0x2E,
  1072.     kSelectVDSetFieldPreference = 0x2F,
  1073.     kSelectVDGetFieldPreference = 0x30,
  1074.     kSelectVDPreflightDestination = 0x32,
  1075.     kSelectVDPreflightGlobalRect = 0x33,
  1076.     kSelectVDSetPlayThruGlobalRect = 0x34,
  1077.     kSelectVDSetInputGammaRecord = 0x35,
  1078.     kSelectVDGetInputGammaRecord = 0x36,
  1079.     kSelectVDSetBlackLevelValue = 0x37,
  1080.     kSelectVDGetBlackLevelValue = 0x38,
  1081.     kSelectVDSetWhiteLevelValue = 0x39,
  1082.     kSelectVDGetWhiteLevelValue = 0x3A,
  1083.     kSelectVDGetVideoDefaults = 0x3B,
  1084.     kSelectVDGetNumberOfInputs = 0x3C,
  1085.     kSelectVDGetInputFormat = 0x3D,
  1086.     kSelectVDSetInput = 0x3E,
  1087.     kSelectVDGetInput = 0x3F,
  1088.     kSelectVDSetInputStandard = 0x40,
  1089.     kSelectVDSetupBuffers = 0x41,
  1090.     kSelectVDGrabOneFrameAsync = 0x42,
  1091.     kSelectVDDone = 0x43,
  1092.     kSelectVDSetCompression = 0x44,
  1093.     kSelectVDCompressOneFrameAsync = 0x45,
  1094.     kSelectVDCompressDone = 0x46,
  1095.     kSelectVDReleaseCompressBuffer = 0x47,
  1096.     kSelectVDGetImageDescription = 0x48,
  1097.     kSelectVDResetCompressSequence = 0x49,
  1098.     kSelectVDSetCompressionOnOff = 0x4A,
  1099.     kSelectVDGetCompressionTypes = 0x4B,
  1100.     kSelectVDSetTimeBase = 0x4C,
  1101.     kSelectVDSetFrameRate = 0x4D,
  1102.     kSelectVDGetDataRate = 0x4E,
  1103.     kSelectVDGetSoundInputDriver = 0x4F,
  1104.     kSelectVDGetDMADepths = 0x50,
  1105.     kSelectVDGetPreferredTimeScale = 0x51,
  1106.     kSelectVDReleaseAsyncBuffers = 0x52 
  1107. };
  1108. #define    StandardCompressionType        'scdi'
  1109. #define    StandardCompressionSubType    'imag'
  1110.  
  1111.  
  1112. typedef pascal Boolean (*SCModalFilterProcPtr)(DialogPtr theDialog,
  1113.     EventRecord *theEvent, short *itemHit, long refcon);
  1114.  
  1115. typedef pascal short (*SCModalHookProcPtr)(DialogPtr theDialog,
  1116.     short itemHit, void *params, long refcon);
  1117.  
  1118.  
  1119. //    Preference flags.
  1120.  
  1121. #define    scListEveryCodec        (1L<<1)
  1122. #define    scAllowZeroFrameRate    (1L<<2)
  1123. #define    scAllowZeroKeyFrameRate    (1L<<3)
  1124. #define    scShowBestDepth            (1L<<4)
  1125. #define    scUseMovableModal        (1L<<5)
  1126.  
  1127.  
  1128. //    Possible test flags for setting test image.
  1129.  
  1130. #define    scPreferCropping            (1<<0)
  1131. #define    scPreferScaling                (1<<1)
  1132. #define scPreferScalingAndCropping    (scPreferScaling + scPreferCropping)
  1133.  
  1134.  
  1135. //    Dimensions of the image preview box.
  1136.  
  1137. #define    scTestImageWidth    80
  1138. #define    scTestImageHeight    80
  1139.  
  1140.  
  1141. //    Possible items returned by hookProc.
  1142.  
  1143. #define    scOKItem                1
  1144. #define    scCancelItem            2
  1145. #define    scCustomItem            3
  1146.  
  1147. //    Result returned when user cancelled.
  1148.  
  1149. #define    scUserCancelled            1
  1150.  
  1151.  
  1152. // Component selectors
  1153.  
  1154. #define    scPositionRect                2
  1155. #define    scPositionDialog            3
  1156. #define    scSetTestImagePictHandle    4
  1157. #define    scSetTestImagePictFile        5
  1158. #define    scSetTestImagePixMap        6
  1159. #define    scGetBestDeviceRect            7
  1160.  
  1161. #define    scRequestImageSettings        10
  1162. #define    scCompressImage                11
  1163. #define    scCompressPicture            12
  1164. #define    scCompressPictureFile        13
  1165. #define    scRequestSequenceSettings    14
  1166. #define    scCompressSequenceBegin        15
  1167. #define    scCompressSequenceFrame        16
  1168. #define    scCompressSequenceEnd        17
  1169. #define    scDefaultPictHandleSettings    18
  1170. #define    scDefaultPictFileSettings    19
  1171. #define    scDefaultPixMapSettings        20
  1172. #define    scGetInfo                    21
  1173. #define    scSetInfo                    22
  1174. #define    scNewGWorld                    23
  1175.  
  1176.  
  1177. //    Get/SetInfo structures.
  1178.  
  1179. typedef struct {
  1180.     CodecType        codecType;
  1181.     CodecComponent    codec;
  1182.     short            depth;
  1183.     CodecQ            spatialQuality;
  1184. } SCSpatialSettings;
  1185.  
  1186. typedef struct {
  1187.     CodecQ            temporalQuality;
  1188.     Fixed            frameRate;
  1189.     long            keyFrameRate;
  1190. } SCTemporalSettings;
  1191.  
  1192. typedef struct {
  1193.     long            dataRate;
  1194.     long            frameDuration;
  1195.     CodecQ            minSpatialQuality;
  1196.     CodecQ            minTemporalQuality;
  1197. } SCDataRateSettings;
  1198.  
  1199. typedef struct {
  1200.     SCModalFilterProcPtr    filterProc;
  1201.     SCModalHookProcPtr        hookProc;
  1202.     long                    refcon;
  1203.     Str31                    customName;
  1204. } SCExtendedProcs;
  1205.  
  1206.  
  1207. //    Get/SetInfo selectors
  1208.  
  1209. #define    scSpatialSettingsType    'sptl'        // pointer to SCSpatialSettings struct
  1210. #define    scTemporalSettingsType    'tprl'        // pointer to SCTemporalSettings struct
  1211. #define    scDataRateSettingsType    'drat'        // pointer to SCDataRateSettings struct
  1212. #define    scColorTableType        'clut'        // pointer to CTabHandle
  1213. #define    scProgressProcType        'prog'        // pointer to ProgressRecord struct
  1214. #define    scExtendedProcsType        'xprc'        // pointer to SCExtendedProcs struct
  1215. #define    scPreferenceFlagsType    'pref'        // pointer to long
  1216. #define    scSettingsStateType        'ssta'        // pointer to Handle
  1217. #define    scSequenceIDType        'sequ'        // pointer to ImageSequence
  1218. #define    scWindowPositionType    'wndw'        // pointer to Point
  1219. #define    scCodecFlagsType        'cflg'        // pointer to CodecFlags
  1220. #define    scCodecSettingsType        'cdec'        // pointer to Handle
  1221.  
  1222.  
  1223. //    Result returned by Get/SetInfo when type cannot be found.
  1224.  
  1225. #define    scTypeNotFoundErr        -8971        // same number as codecExtensionNotFoundErr
  1226.  
  1227.  
  1228.  
  1229. #ifdef __cplusplus
  1230. extern "C" {
  1231. #endif
  1232.  
  1233. pascal ComponentResult
  1234. SCPositionRect(ComponentInstance ci,Rect *rp,Point *where)
  1235.     = {0x2F3C,0x8,0x2,0x7000,0xA82A};
  1236.  
  1237. pascal ComponentResult
  1238. SCPositionDialog(ComponentInstance ci,short id,Point *where)
  1239.     = {0x2F3C,0x6,0x3,0x7000,0xA82A};
  1240.  
  1241. pascal ComponentResult
  1242. SCSetTestImagePictHandle(ComponentInstance ci, PicHandle testPict, Rect *testRect, short testFlags)
  1243.     = {0x2F3C,0xA,0x4,0x7000,0xA82A};
  1244.  
  1245. pascal ComponentResult
  1246. SCSetTestImagePictFile(ComponentInstance ci, short testFileRef, Rect *testRect, short testFlags)
  1247.     = {0x2F3C,0x8,0x5,0x7000,0xA82A};
  1248.  
  1249. pascal ComponentResult
  1250. SCSetTestImagePixMap(ComponentInstance ci, PixMapHandle testPixMap, Rect *testRect, short testFlags)
  1251.     = {0x2F3C,0xA,0x6,0x7000,0xA82A};
  1252.  
  1253. pascal ComponentResult
  1254. SCGetBestDeviceRect(ComponentInstance ci, Rect *r) 
  1255.      = {0x2F3C,0x4,0x7,0x7000,0xA82A};
  1256.  
  1257.  
  1258.  
  1259. pascal ComponentResult
  1260. SCRequestImageSettings(ComponentInstance ci)
  1261.     = {0x2F3C,0,0xA,0x7000,0xA82A};
  1262.  
  1263. pascal ComponentResult
  1264. SCCompressImage(ComponentInstance ci,PixMapHandle src,Rect *srcRect,ImageDescriptionHandle *desc,Handle *data)
  1265.     = {0x2F3C,0x10,0xB,0x7000,0xA82A};
  1266.  
  1267. pascal ComponentResult
  1268. SCCompressPicture(ComponentInstance ci,PicHandle srcPicture,PicHandle dstPicture)
  1269.     = {0x2F3C,0x8,0xC,0x7000,0xA82A};
  1270.  
  1271. pascal ComponentResult
  1272. SCCompressPictureFile(ComponentInstance ci,short srcRefNum,short dstRefNum)
  1273.     = {0x2F3C,0x4,0xD,0x7000,0xA82A};
  1274.  
  1275. pascal ComponentResult
  1276. SCRequestSequenceSettings(ComponentInstance ci)
  1277.     = {0x2F3C,0,0xE,0x7000,0xA82A};
  1278.  
  1279. pascal ComponentResult
  1280. SCCompressSequenceBegin(ComponentInstance ci,PixMapHandle src,Rect *srcRect,ImageDescriptionHandle *desc)
  1281.     = {0x2F3C,0xC,0xF,0x7000,0xA82A};
  1282.  
  1283. pascal ComponentResult
  1284. SCCompressSequenceFrame(ComponentInstance ci,PixMapHandle src,Rect *srcRect,Handle *data,long *dataSize,short *notSyncFlag)
  1285.     = {0x2F3C,0x14,0x10,0x7000,0xA82A};
  1286.  
  1287. pascal ComponentResult
  1288. SCCompressSequenceEnd(ComponentInstance ci)
  1289.     = {0x2F3C,0,0x11,0x7000,0xA82A};
  1290.  
  1291. pascal ComponentResult
  1292. SCDefaultPictHandleSettings(ComponentInstance ci,PicHandle srcPicture, short motion)
  1293.     = {0x2F3C,0x6,0x12,0x7000,0xA82A};
  1294.  
  1295. pascal ComponentResult
  1296. SCDefaultPictFileSettings(ComponentInstance ci,short srcRef, short motion)
  1297.     = {0x2F3C,0x4,0x13,0x7000,0xA82A};
  1298.  
  1299. pascal ComponentResult
  1300. SCDefaultPixMapSettings(ComponentInstance ci,PixMapHandle src, short motion)
  1301.     = {0x2F3C,0x6,0x14,0x7000,0xA82A};
  1302.  
  1303. pascal ComponentResult
  1304. SCGetInfo(ComponentInstance ci,OSType type,void *info)
  1305.     = {0x2F3C,0x8,0x15,0x7000,0xA82A};
  1306.  
  1307. pascal ComponentResult
  1308. SCSetInfo(ComponentInstance ci,OSType type,void *info)
  1309.     = {0x2F3C,0x8,0x16,0x7000,0xA82A};
  1310.  
  1311. pascal ComponentResult
  1312. SCNewGWorld(ComponentInstance ci,GWorldPtr *gwp,Rect *rp,GWorldFlags flags)
  1313.     = {0x2F3C,0xC,0x17,0x7000,0xA82A};
  1314.  
  1315. #ifdef __cplusplus
  1316. }
  1317. #endif
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323. // For compatibility with earlier linked StdCompression.
  1324.  
  1325. typedef struct {
  1326.     long            flags;
  1327.     CodecType        theCodecType;
  1328.     CodecComponent    theCodec;
  1329.     CodecQ            spatialQuality;
  1330.     CodecQ            temporalQuality;
  1331.     short            depth;
  1332.     Fixed            frameRate;
  1333.     long            keyFrameRate;
  1334.     long            reserved1;
  1335.     long            reserved2;
  1336. } SCParams;
  1337.  
  1338.  
  1339. #define    scGetCompression        1
  1340.  
  1341. #define    scShowMotionSettings    (1L<<0)
  1342.  
  1343. #define    scSettingsChangedItem    -1
  1344.  
  1345.  
  1346. #ifdef __cplusplus
  1347. extern "C" {
  1348. #endif
  1349.  
  1350. pascal ComponentInstance OpenStdCompression(void);
  1351.  
  1352. pascal ComponentResult
  1353. SCGetCompressionExtended(ComponentInstance ci,SCParams *params,Point where,
  1354.     SCModalFilterProcPtr filterProc,SCModalHookProcPtr hookProc,long refcon,StringPtr customName)
  1355.     = {0x2F3C,0x18,0x1,0x7000,0xA82A};
  1356.  
  1357. pascal ComponentResult
  1358. SCGetCompression(ComponentInstance ci,SCParams *params,Point where)
  1359.     = {0x42A7,0x42A7,0x42A7,0x42A7,0x2F3C,0x18,0x1,0x7000,0xA82A};
  1360.  
  1361. #ifdef __cplusplus
  1362. }
  1363. #endif
  1364.  
  1365.  
  1366.  
  1367.  
  1368. typedef ComponentInstance MovieImportComponent, MovieExportComponent;
  1369.  
  1370. #define MovieImportType 'eat '
  1371. #define MovieExportType 'spit'
  1372.  
  1373. enum {
  1374.     canMovieImportHandles = 1,
  1375.     canMovieImportFiles = 2,
  1376.     hasMovieImportUserInterface = 4,
  1377.     canMovieExportHandles = 8,
  1378.     canMovieExportFiles = 16,
  1379.     hasMovieExportUserInterface = 32,
  1380.     dontAutoFileMovieImport = 64,
  1381.     canMovieExportAuxDataHandle = 128,
  1382.     canMovieImportValidateHandles = 256,
  1383.     canMovieImportValidateFile = 512,
  1384.     dontRegisterWithEasyOpen = 1024
  1385. };
  1386.  
  1387. enum {
  1388.     kMovieImportExportOpenSelect = kComponentOpenSelect,
  1389.     kMovieImportExportCloseSelect = kComponentCloseSelect,
  1390.     kMovieImportExportCanDoSelect = kComponentCanDoSelect,
  1391.     kMovieImportExportVersionSelect = kComponentVersionSelect, 
  1392.  
  1393.     kMovieImportHandleSelect = 1,
  1394.     kMovieImportFileSelect = 2,
  1395.     kMovieImportSetSampleDurationSelect = 3,
  1396.     kMovieImportSetSampleDescriptionSelect = 4,
  1397.     kMovieImportSetMediaFileSelect = 5,
  1398.     kMovieImportSetDimensionsSelect = 6,
  1399.     kMovieImportSetChunkSizeSelect = 7,
  1400.     kMovieImportSetProgressProcSelect = 8,
  1401.     kMovieImportSetAuxiliaryDataSelect = 9,
  1402.     kMovieImportSetFromScrapSelect = 10,
  1403.     kMovieImportDoUserDialogSelect = 11,
  1404.     kMovieImportSetDurationSelect = 12,
  1405.     kMovieImportGetAuxiliaryDataTypeSelect = 13,
  1406.     kMovieImportValidateSelect = 14,
  1407.     
  1408.     kMovieExportToHandleSelect = 128,
  1409.     kMovieExportToFileSelect = 129,
  1410.     kMovieExportDoUserDialogSelect = 130,
  1411.     kMovieExportGetAuxiliaryDataSelect = 131,
  1412.     kMovieExportSetProgressProcSelect = 132,
  1413.     kMovieExportSetSampleDescriptionSelect = 133
  1414. };
  1415.  
  1416. enum {
  1417.     movieImportCreateTrack = 1,
  1418.     movieImportInParallel = 2,
  1419.     movieImportMustUseTrack = 4
  1420. };
  1421.  
  1422. enum {
  1423.     movieImportResultUsedMultipleTracks = 8
  1424. };
  1425.  
  1426. #ifdef __cplusplus
  1427. extern "C" {
  1428. #endif __cplusplus
  1429.  
  1430. pascal ComponentResult MovieImportHandle(MovieImportComponent ci, Handle dataH,
  1431.         Movie theMovie, Track targetTrack, Track *usedTrack, TimeValue atTime, TimeValue *addedDuration,
  1432.         long inFlags, long *outFlags) = {0x2F3C,0x20,0x1,0x7000,0xA82A};
  1433.  
  1434. pascal ComponentResult MovieImportFile(MovieImportComponent ci, const FSSpec *theFile,
  1435.         Movie theMovie, Track targetTrack, Track *usedTrack, TimeValue atTime, TimeValue *addedDuration,
  1436.         long inFlags, long *outFlags) = {0x2F3C,0x20,0x2,0x7000,0xA82A};
  1437.  
  1438. pascal ComponentResult MovieImportSetSampleDuration(MovieImportComponent ci, TimeValue duration, TimeScale scale) = {0x2F3C,0x8,0x3,0x7000,0xA82A};
  1439.  
  1440. pascal ComponentResult MovieImportSetSampleDescription(MovieImportComponent ci, SampleDescriptionHandle desc, OSType mediaType) = {0x2F3C,0x8,0x4,0x7000,0xA82A};
  1441.  
  1442. pascal ComponentResult MovieImportSetMediaFile(MovieImportComponent ci, AliasHandle alias) = {0x2F3C,0x4,0x5,0x7000,0xA82A};
  1443.  
  1444. pascal ComponentResult MovieImportSetDimensions(MovieImportComponent ci, Fixed width, Fixed height) = {0x2F3C,0x8,0x6,0x7000,0xA82A};
  1445.  
  1446. pascal ComponentResult MovieImportSetChunkSize(MovieImportComponent ci, long chunkSize) = {0x2F3C,0x4,0x7,0x7000,0xA82A};
  1447.  
  1448. pascal ComponentResult MovieImportSetProgressProc(MovieImportComponent ci, MovieProgressProcPtr proc, long refcon) = {0x2F3C,0x8,0x8,0x7000,0xA82A};
  1449.  
  1450. pascal ComponentResult MovieImportSetAuxiliaryData(MovieImportComponent ci, Handle data, OSType handleType) = {0x2F3C,0x8,0x9,0x7000,0xA82A};
  1451.  
  1452. pascal ComponentResult MovieImportSetFromScrap(MovieImportComponent ci, Boolean fromScrap) = {0x2F3C,0x2,0xA,0x7000,0xA82A};
  1453.  
  1454. pascal ComponentResult MovieImportDoUserDialog(MovieImportComponent ci, const FSSpec *theFile, Handle theData, Boolean *canceled) = {0x2F3C,0xC,0xB,0x7000,0xA82A};
  1455.  
  1456. pascal ComponentResult MovieImportSetDuration(MovieImportComponent ci, TimeValue duration) = {0x2F3C,0x4,0xC,0x7000,0xA82A};
  1457.  
  1458. pascal ComponentResult MovieImportGetAuxiliaryDataType(MovieImportComponent ci, OSType *auxType) = {0x2F3C,0x4,0xD,0x7000,0xA82A};
  1459.  
  1460. pascal ComponentResult MovieImportValidate(MovieImportComponent ci, const FSSpec *theFile, Handle theData, Boolean *valid) = {0x2F3C,0xC,0xE,0x7000,0xA82A};
  1461.  
  1462.  
  1463. pascal ComponentResult MovieExportToHandle(MovieExportComponent ci, Handle dataH, Movie theMovie, Track onlyThisTrack, TimeValue startTime,
  1464.     TimeValue duration) = {0x2F3C,0x14,0x80,0x7000,0xA82A};
  1465.  
  1466. pascal ComponentResult MovieExportToFile(MovieExportComponent ci, const FSSpec *theFile, Movie theMovie, Track onlyThisTrack, TimeValue startTime,
  1467.     TimeValue duration) = {0x2F3C,0x14,0x81,0x7000,0xA82A};
  1468.  
  1469. pascal ComponentResult MovieExportDoUserDialog(MovieExportComponent ci, const FSSpec *theFile, Handle theData, Boolean *canceled) = {0x2F3C,0xC,0x82,0x7000,0xA82A};
  1470.  
  1471. pascal ComponentResult MovieExportGetAuxiliaryData(MovieExportComponent ci, Handle dataH, OSType *handleType) = {0x2F3C,0x8,0x83,0x7000,0xA82A};
  1472.  
  1473. pascal ComponentResult MovieExportSetProgressProc(MovieExportComponent ci, MovieProgressProcPtr proc, long refcon) = {0x2F3C,0x8,0x84,0x7000,0xA82A};
  1474.  
  1475. pascal ComponentResult MovieExportSetSampleDescription(MovieExportComponent ci, SampleDescriptionHandle desc, OSType mediaType) = {0x2F3C,0x8,0x85,0x7000,0xA82A};
  1476.  
  1477.  
  1478. // Text Export Display Info data structure
  1479. typedef struct {
  1480.     long        displayFlags;
  1481.     long         textJustification;
  1482.     RGBColor     bgColor;
  1483.     Rect        textBox;
  1484.     
  1485.     short        beginHilite;
  1486.     short        endHilite;
  1487.     RGBColor     hiliteColor;
  1488.     Boolean        doHiliteColor;
  1489.     TimeValue     scrollDelayDur;
  1490.     Point        dropShadowOffset;
  1491.     short        dropShadowTransparency;
  1492. } TextDisplayData;
  1493.  
  1494. typedef ComponentInstance TextExportComponent;
  1495. pascal ComponentResult TextExportGetDisplayData(TextExportComponent ci, TextDisplayData *textDisplay) = {0x2F3C,0x4,0x100,0x7000,0xA82A};
  1496.  
  1497. #ifdef __cplusplus
  1498. }
  1499. #endif __cplusplus
  1500.  
  1501. /***************
  1502.  
  1503.     File Preview Components
  1504.  
  1505. ***************/
  1506.  
  1507. typedef ComponentInstance pnotComponent;
  1508.  
  1509. enum {
  1510.     pnotComponentWantsEvents = 1,
  1511.     pnotComponentNeedsNoCache = 2
  1512. };
  1513.  
  1514. enum {
  1515.     kPreviewOpenSelector = 0,
  1516.     kPreviewCloseSelector = -1,
  1517.     kPreviewCanDoSelector = -2,
  1518.     kPreviewVersionSelector = -3, 
  1519.  
  1520.     kPreviewShowDataSelector = 1,
  1521.     kPreviewMakePreviewSelector = 2,
  1522.     kPreviewMakePreviewReferenceSelector = 3,
  1523.     kPreviewEventSelector = 4
  1524. };
  1525.  
  1526. #define ShowFilePreviewComponentType 'pnot'
  1527. #define CreateFilePreviewComponentType 'pmak'
  1528.  
  1529. #ifdef __cplusplus
  1530. extern "C" {
  1531. #endif __cplusplus
  1532.  
  1533. pascal ComponentResult PreviewShowData(pnotComponent p, OSType dataType, Handle data,
  1534.         const Rect *inHere) = {0x2F3C,0xC,0x1,0x7000,0xA82A};
  1535.  
  1536. pascal ComponentResult PreviewMakePreview(pnotComponent p, OSType *previewType, Handle *previewResult,
  1537.             const FSSpec *sourceFile, ProgressProcRecordPtr progress) = {0x2F3C,0x10,0x2,0x7000,0xA82A};
  1538.  
  1539. pascal ComponentResult PreviewMakePreviewReference(pnotComponent p, OSType *previewType, short *resID,
  1540.             const FSSpec *sourceFile) = {0x2F3C,0xC,0x3,0x7000,0xA82A};
  1541.  
  1542. pascal ComponentResult PreviewEvent(pnotComponent p, EventRecord *e, Boolean *handledEvent) = {0x2F3C,0x8,0x4,0x7000,0xA82A};
  1543. #ifdef __cplusplus
  1544. }
  1545. #endif __cplusplus
  1546. #endif __QUICKTIMECOMPONENTS__
  1547.